3.497 \(\int \frac{(d+e x) (a+b \tanh ^{-1}(c x))^2}{1-c^2 x^2} \, dx\)

Optimal. Leaf size=122 \[ \frac{b e \text{PolyLog}\left (2,1-\frac{2}{1-c x}\right ) \left (a+b \tanh ^{-1}(c x)\right )}{c^2}-\frac{b^2 e \text{PolyLog}\left (3,1-\frac{2}{1-c x}\right )}{2 c^2}-\frac{e \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c^2}+\frac{e \log \left (\frac{2}{1-c x}\right ) \left (a+b \tanh ^{-1}(c x)\right )^2}{c^2}+\frac{d \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c} \]

[Out]

(d*(a + b*ArcTanh[c*x])^3)/(3*b*c) - (e*(a + b*ArcTanh[c*x])^3)/(3*b*c^2) + (e*(a + b*ArcTanh[c*x])^2*Log[2/(1
 - c*x)])/c^2 + (b*e*(a + b*ArcTanh[c*x])*PolyLog[2, 1 - 2/(1 - c*x)])/c^2 - (b^2*e*PolyLog[3, 1 - 2/(1 - c*x)
])/(2*c^2)

________________________________________________________________________________________

Rubi [A]  time = 0.318412, antiderivative size = 122, normalized size of antiderivative = 1., number of steps used = 7, number of rules used = 6, integrand size = 28, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.214, Rules used = {6048, 5948, 5984, 5918, 6058, 6610} \[ \frac{b e \text{PolyLog}\left (2,1-\frac{2}{1-c x}\right ) \left (a+b \tanh ^{-1}(c x)\right )}{c^2}-\frac{b^2 e \text{PolyLog}\left (3,1-\frac{2}{1-c x}\right )}{2 c^2}-\frac{e \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c^2}+\frac{e \log \left (\frac{2}{1-c x}\right ) \left (a+b \tanh ^{-1}(c x)\right )^2}{c^2}+\frac{d \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c} \]

Antiderivative was successfully verified.

[In]

Int[((d + e*x)*(a + b*ArcTanh[c*x])^2)/(1 - c^2*x^2),x]

[Out]

(d*(a + b*ArcTanh[c*x])^3)/(3*b*c) - (e*(a + b*ArcTanh[c*x])^3)/(3*b*c^2) + (e*(a + b*ArcTanh[c*x])^2*Log[2/(1
 - c*x)])/c^2 + (b*e*(a + b*ArcTanh[c*x])*PolyLog[2, 1 - 2/(1 - c*x)])/c^2 - (b^2*e*PolyLog[3, 1 - 2/(1 - c*x)
])/(2*c^2)

Rule 6048

Int[(((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)*((f_) + (g_.)*(x_))^(m_.))/((d_) + (e_.)*(x_)^2), x_Symbol] :>
Int[ExpandIntegrand[(a + b*ArcTanh[c*x])^p/(d + e*x^2), (f + g*x)^m, x], x] /; FreeQ[{a, b, c, d, e, f, g}, x]
 && IGtQ[p, 0] && EqQ[c^2*d + e, 0] && IGtQ[m, 0]

Rule 5948

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)/((d_) + (e_.)*(x_)^2), x_Symbol] :> Simp[(a + b*ArcTanh[c*x])^(p
 + 1)/(b*c*d*(p + 1)), x] /; FreeQ[{a, b, c, d, e, p}, x] && EqQ[c^2*d + e, 0] && NeQ[p, -1]

Rule 5984

Int[(((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)*(x_))/((d_) + (e_.)*(x_)^2), x_Symbol] :> Simp[(a + b*ArcTanh[c
*x])^(p + 1)/(b*e*(p + 1)), x] + Dist[1/(c*d), Int[(a + b*ArcTanh[c*x])^p/(1 - c*x), x], x] /; FreeQ[{a, b, c,
 d, e}, x] && EqQ[c^2*d + e, 0] && IGtQ[p, 0]

Rule 5918

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)/((d_) + (e_.)*(x_)), x_Symbol] :> -Simp[((a + b*ArcTanh[c*x])^p*
Log[2/(1 + (e*x)/d)])/e, x] + Dist[(b*c*p)/e, Int[((a + b*ArcTanh[c*x])^(p - 1)*Log[2/(1 + (e*x)/d)])/(1 - c^2
*x^2), x], x] /; FreeQ[{a, b, c, d, e}, x] && IGtQ[p, 0] && EqQ[c^2*d^2 - e^2, 0]

Rule 6058

Int[(Log[u_]*((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.))/((d_) + (e_.)*(x_)^2), x_Symbol] :> -Simp[((a + b*ArcT
anh[c*x])^p*PolyLog[2, 1 - u])/(2*c*d), x] + Dist[(b*p)/2, Int[((a + b*ArcTanh[c*x])^(p - 1)*PolyLog[2, 1 - u]
)/(d + e*x^2), x], x] /; FreeQ[{a, b, c, d, e}, x] && IGtQ[p, 0] && EqQ[c^2*d + e, 0] && EqQ[(1 - u)^2 - (1 -
2/(1 - c*x))^2, 0]

Rule 6610

Int[(u_)*PolyLog[n_, v_], x_Symbol] :> With[{w = DerivativeDivides[v, u*v, x]}, Simp[w*PolyLog[n + 1, v], x] /
;  !FalseQ[w]] /; FreeQ[n, x]

Rubi steps

\begin{align*} \int \frac{(d+e x) \left (a+b \tanh ^{-1}(c x)\right )^2}{1-c^2 x^2} \, dx &=\int \left (\frac{d \left (a+b \tanh ^{-1}(c x)\right )^2}{1-c^2 x^2}+\frac{e x \left (a+b \tanh ^{-1}(c x)\right )^2}{1-c^2 x^2}\right ) \, dx\\ &=d \int \frac{\left (a+b \tanh ^{-1}(c x)\right )^2}{1-c^2 x^2} \, dx+e \int \frac{x \left (a+b \tanh ^{-1}(c x)\right )^2}{1-c^2 x^2} \, dx\\ &=\frac{d \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c}-\frac{e \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c^2}+\frac{e \int \frac{\left (a+b \tanh ^{-1}(c x)\right )^2}{1-c x} \, dx}{c}\\ &=\frac{d \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c}-\frac{e \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c^2}+\frac{e \left (a+b \tanh ^{-1}(c x)\right )^2 \log \left (\frac{2}{1-c x}\right )}{c^2}-\frac{(2 b e) \int \frac{\left (a+b \tanh ^{-1}(c x)\right ) \log \left (\frac{2}{1-c x}\right )}{1-c^2 x^2} \, dx}{c}\\ &=\frac{d \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c}-\frac{e \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c^2}+\frac{e \left (a+b \tanh ^{-1}(c x)\right )^2 \log \left (\frac{2}{1-c x}\right )}{c^2}+\frac{b e \left (a+b \tanh ^{-1}(c x)\right ) \text{Li}_2\left (1-\frac{2}{1-c x}\right )}{c^2}-\frac{\left (b^2 e\right ) \int \frac{\text{Li}_2\left (1-\frac{2}{1-c x}\right )}{1-c^2 x^2} \, dx}{c}\\ &=\frac{d \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c}-\frac{e \left (a+b \tanh ^{-1}(c x)\right )^3}{3 b c^2}+\frac{e \left (a+b \tanh ^{-1}(c x)\right )^2 \log \left (\frac{2}{1-c x}\right )}{c^2}+\frac{b e \left (a+b \tanh ^{-1}(c x)\right ) \text{Li}_2\left (1-\frac{2}{1-c x}\right )}{c^2}-\frac{b^2 e \text{Li}_3\left (1-\frac{2}{1-c x}\right )}{2 c^2}\\ \end{align*}

Mathematica [A]  time = 0.386973, size = 193, normalized size = 1.58 \[ \frac{-6 b e \text{PolyLog}\left (2,-e^{-2 \tanh ^{-1}(c x)}\right ) \left (a+b \tanh ^{-1}(c x)\right )-3 b^2 e \text{PolyLog}\left (3,-e^{-2 \tanh ^{-1}(c x)}\right )-3 a^2 c d \log (1-c x)+3 a^2 c d \log (c x+1)-3 a^2 e \log (1-c x)-3 a^2 e \log (c x+1)+6 a b c d \tanh ^{-1}(c x)^2+6 a b e \tanh ^{-1}(c x)^2+12 a b e \tanh ^{-1}(c x) \log \left (e^{-2 \tanh ^{-1}(c x)}+1\right )+2 b^2 c d \tanh ^{-1}(c x)^3+2 b^2 e \tanh ^{-1}(c x)^3+6 b^2 e \tanh ^{-1}(c x)^2 \log \left (e^{-2 \tanh ^{-1}(c x)}+1\right )}{6 c^2} \]

Warning: Unable to verify antiderivative.

[In]

Integrate[((d + e*x)*(a + b*ArcTanh[c*x])^2)/(1 - c^2*x^2),x]

[Out]

(6*a*b*c*d*ArcTanh[c*x]^2 + 6*a*b*e*ArcTanh[c*x]^2 + 2*b^2*c*d*ArcTanh[c*x]^3 + 2*b^2*e*ArcTanh[c*x]^3 + 12*a*
b*e*ArcTanh[c*x]*Log[1 + E^(-2*ArcTanh[c*x])] + 6*b^2*e*ArcTanh[c*x]^2*Log[1 + E^(-2*ArcTanh[c*x])] - 3*a^2*c*
d*Log[1 - c*x] - 3*a^2*e*Log[1 - c*x] + 3*a^2*c*d*Log[1 + c*x] - 3*a^2*e*Log[1 + c*x] - 6*b*e*(a + b*ArcTanh[c
*x])*PolyLog[2, -E^(-2*ArcTanh[c*x])] - 3*b^2*e*PolyLog[3, -E^(-2*ArcTanh[c*x])])/(6*c^2)

________________________________________________________________________________________

Maple [C]  time = 0.444, size = 1871, normalized size = 15.3 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((e*x+d)*(a+b*arctanh(c*x))^2/(-c^2*x^2+1),x)

[Out]

1/4*I/c^2*b^2*arctanh(c*x)^2*csgn(I*(c*x+1)^2/(c^2*x^2-1)/((c*x+1)^2/(-c^2*x^2+1)+1))^2*csgn(I/((c*x+1)^2/(-c^
2*x^2+1)+1))*Pi*e-1/2*I/c*b^2*arctanh(c*x)^2*csgn(I*(c*x+1)/(-c^2*x^2+1)^(1/2))*csgn(I*(c*x+1)^2/(c^2*x^2-1))^
2*Pi*d-1/4*I/c*b^2*arctanh(c*x)^2*csgn(I*(c*x+1)^2/(c^2*x^2-1)/((c*x+1)^2/(-c^2*x^2+1)+1))^2*csgn(I/((c*x+1)^2
/(-c^2*x^2+1)+1))*Pi*d-1/4*I/c*b^2*arctanh(c*x)^2*csgn(I*(c*x+1)/(-c^2*x^2+1)^(1/2))^2*csgn(I*(c*x+1)^2/(c^2*x
^2-1))*Pi*d+1/4*I/c*b^2*arctanh(c*x)^2*csgn(I*(c*x+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2*b^2
*arctanh(c*x)^2*ln(c*x-1)*e+1/c^2*b^2*arctanh(c*x)^2*ln(2)*e+1/4/c^2*a*b*ln(c*x+1)^2*e+1/c^2*a*b*dilog(1/2+1/2
*c*x)*e-1/4/c^2*a*b*ln(c*x-1)^2*e-1/2/c^2*b^2*arctanh(c*x)^2*ln(c*x+1)*e+1/c^2*b^2*arctanh(c*x)^2*ln((c*x+1)/(
-c^2*x^2+1)^(1/2))*e+1/c^2*b^2*e*arctanh(c*x)*polylog(2,-(c*x+1)^2/(-c^2*x^2+1))

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} a b d{\left (\frac{\log \left (c x + 1\right )}{c} - \frac{\log \left (c x - 1\right )}{c}\right )} \operatorname{artanh}\left (c x\right ) + \frac{1}{2} \, a^{2} d{\left (\frac{\log \left (c x + 1\right )}{c} - \frac{\log \left (c x - 1\right )}{c}\right )} - \frac{{\left (\log \left (c x + 1\right )^{2} - 2 \, \log \left (c x + 1\right ) \log \left (c x - 1\right ) + \log \left (c x - 1\right )^{2}\right )} a b d}{4 \, c} - \frac{a^{2} e \log \left (c^{2} x^{2} - 1\right )}{2 \, c^{2}} + \frac{3 \,{\left (c d - e\right )} b^{2} \log \left (c x + 1\right ) \log \left (-c x + 1\right )^{2} -{\left (c d + e\right )} b^{2} \log \left (-c x + 1\right )^{3}}{24 \, c^{2}} - \int \frac{4 \, a b c e x \log \left (c x + 1\right ) +{\left (b^{2} c e x + b^{2} c d\right )} \log \left (c x + 1\right )^{2} -{\left (4 \, a b c e x -{\left ({\left (c^{2} d - 3 \, c e\right )} b^{2} x -{\left (c d + e\right )} b^{2}\right )} \log \left (c x + 1\right )\right )} \log \left (-c x + 1\right )}{4 \,{\left (c^{3} x^{2} - c\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*arctanh(c*x))^2/(-c^2*x^2+1),x, algorithm="maxima")

[Out]

a*b*d*(log(c*x + 1)/c - log(c*x - 1)/c)*arctanh(c*x) + 1/2*a^2*d*(log(c*x + 1)/c - log(c*x - 1)/c) - 1/4*(log(
c*x + 1)^2 - 2*log(c*x + 1)*log(c*x - 1) + log(c*x - 1)^2)*a*b*d/c - 1/2*a^2*e*log(c^2*x^2 - 1)/c^2 + 1/24*(3*
(c*d - e)*b^2*log(c*x + 1)*log(-c*x + 1)^2 - (c*d + e)*b^2*log(-c*x + 1)^3)/c^2 - integrate(1/4*(4*a*b*c*e*x*l
og(c*x + 1) + (b^2*c*e*x + b^2*c*d)*log(c*x + 1)^2 - (4*a*b*c*e*x - ((c^2*d - 3*c*e)*b^2*x - (c*d + e)*b^2)*lo
g(c*x + 1))*log(-c*x + 1))/(c^3*x^2 - c), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (-\frac{a^{2} e x + a^{2} d +{\left (b^{2} e x + b^{2} d\right )} \operatorname{artanh}\left (c x\right )^{2} + 2 \,{\left (a b e x + a b d\right )} \operatorname{artanh}\left (c x\right )}{c^{2} x^{2} - 1}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*arctanh(c*x))^2/(-c^2*x^2+1),x, algorithm="fricas")

[Out]

integral(-(a^2*e*x + a^2*d + (b^2*e*x + b^2*d)*arctanh(c*x)^2 + 2*(a*b*e*x + a*b*d)*arctanh(c*x))/(c^2*x^2 - 1
), x)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} - \int \frac{a^{2} d}{c^{2} x^{2} - 1}\, dx - \int \frac{a^{2} e x}{c^{2} x^{2} - 1}\, dx - \int \frac{b^{2} d \operatorname{atanh}^{2}{\left (c x \right )}}{c^{2} x^{2} - 1}\, dx - \int \frac{2 a b d \operatorname{atanh}{\left (c x \right )}}{c^{2} x^{2} - 1}\, dx - \int \frac{b^{2} e x \operatorname{atanh}^{2}{\left (c x \right )}}{c^{2} x^{2} - 1}\, dx - \int \frac{2 a b e x \operatorname{atanh}{\left (c x \right )}}{c^{2} x^{2} - 1}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*atanh(c*x))**2/(-c**2*x**2+1),x)

[Out]

-Integral(a**2*d/(c**2*x**2 - 1), x) - Integral(a**2*e*x/(c**2*x**2 - 1), x) - Integral(b**2*d*atanh(c*x)**2/(
c**2*x**2 - 1), x) - Integral(2*a*b*d*atanh(c*x)/(c**2*x**2 - 1), x) - Integral(b**2*e*x*atanh(c*x)**2/(c**2*x
**2 - 1), x) - Integral(2*a*b*e*x*atanh(c*x)/(c**2*x**2 - 1), x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int -\frac{{\left (e x + d\right )}{\left (b \operatorname{artanh}\left (c x\right ) + a\right )}^{2}}{c^{2} x^{2} - 1}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*arctanh(c*x))^2/(-c^2*x^2+1),x, algorithm="giac")

[Out]

integrate(-(e*x + d)*(b*arctanh(c*x) + a)^2/(c^2*x^2 - 1), x)